import request from '@/utils/request'

const api = {
    userList: '/user/list',
    addUser: '/user/add',
    editUser: '/user/edit',
    deleteUser: '/user/delete'
  }

  export function userList (parameter) {
    return request({
      url: api.userList,
      method: 'post',
      data: parameter
    })
  }

  export function addUser (parameter) {
    return request({
      url: api.addUser,
      method: 'post',
      data: parameter
    })
  }

  export function editUser (parameter) {
    return request({
      url: api.editUser,
      method: 'post',
      data: parameter
    })
  }

  export function deleteUser (parameter) {
    return request({
      url: api.deleteUser,
      method: 'post',
      data: parameter
    })
  }
